function checkstate(pkid,bpm_id,sel){
    
	 if(window.confirm('确定要进行此操作码？')){
	  window.location.href='/doTradeReg.do?order_no='+pkid+'&bpm_id='+bpm_id+'&order_state='+sel;
 	}
}

function deleteorder(pkid,bpm_id){
	if(window.confirm('确定要删除吗？')){
		window.location.href='/doTradeReg.do?pkid='+pkid+'&bpm_id='+bpm_id;
	}
}


	function alterState(cust_id,order_no,all_total_amount,index,area_attr){
	  			if(document.getElementById("div"+index).style.display=="none"){
	  				document.getElementById("div"+index).style.display="block";
	  				return;
	  			}
	  		    var no=document.getElementById("peisong_no"+index).value;
	  		    if(no==null||no==""){
	  		    	alert("配送单号不能为空");
	  		    	return;
	  		    }
	  		    var company=document.getElementById("peisong_company"+index).value;
	  		    if(company==null||company==""){
	  		    	alert("配送公司不能为空");
	  		    	return;
	  		    }
	  		    if(cust_id!="100000000000000") document.bpmForm.bpm_id.value="5355";
	  		    document.bpmForm.order_no.value=order_no;
	  		    document.bpmForm.peisong_no.value=no;
	  		    document.bpmForm.peisong_company.value=company;
				document.bpmForm.agent_product_code.value=all_total_amount;
				document.bpmForm.biz_id.value=order_no;
				document.bpmForm.area_attr.value=area_attr;
			
				document.bpmForm.submit();
	  		   /**
	  		    jQuery.ajax({
				   type: 'POST',
				   url: 'ajaxSendGoods.jsp',
				   data: 'order_no='+val+'&peisong_no='+no+'&peisong_company='+company,
		           async:false,									   
				   success: function(data){
		               if(data==0){
	  					alert("操作成功");
	  					document.getElementById("div"+index).style.display="none";
	  					document.getElementById("div"+index+index).innerHTML="已经发货";
	  				}else{
	  					alert("操作失败");
	  				}
				   }
		  		 }); 
	  		   */
	  
	  	}